WDV321 Advanced JavaScript

Unit-1 JavaScript Review Project

Game Input

Difficulty Rating:

Game Options:

Game Library

Instructions:

Dynamic Content:

  1. Use the provided arrays to dynamically populate the Game Type. Include the abbreviations as value attritubes.
  2. Use the provided array to dynamically create a set of radio buttons for Diffulty Rating.
  3. Use the provided array to dynamically create a set of checkboxes for Game Options.
  4. Dynamically load the Copyright year in the footer so that is always the current year.

Data Validation:

  1. Game Name - cannot be blank, max 50 characters
  2. Game Type - one must be selected
  3. Number of Players - must be numeric, 1+, max of 20, whole number
  4. Difficulty Rating - one must be selected
  5. Game Options: Some, none or all may be selected
  6. Game Options: "Fast Play" and "Long Game" cannot both be selected

Data Storage:

  1. Create an object called game for storing the game information. Use a class or object literal.
  2. The game object must allow for any/all selected content.
  3. Create an object called gameLibrary. It will store an array of game objects.

Form Processing:

  1. When the form is submitted by the "Add Game to Library" AND all fields pass validations gather the form data.
  2. Load the game data into a game object
  3. Display the game object in the console
  4. Add the game object to the gameLibrary
  5. Display the gameLibrary in the console
  6. "New Game" button should clear the form entries
  7. "Start Over" button should clear the form, the display and the data.

Display Game Library:

  1. When the "Display Game Library" button is clicked display each game in the game library in the Game Library Area.
  2. Design your own layout and styling for to display the games.